package work.mediway.mdm.core.enums;

import java.util.HashMap;
import java.util.Map;

import lombok.Getter;
import lombok.Setter;

/**
 * 状态
 *
 * @author zhongyj <1126834403@qq.com><br/>
 * @date 2020/12/29
 */
public enum StatusApproveEnum {

    /**
     * 申请中
     */
    STATUS_APPROVE_ING("-1", "申请中"),

    /**
     * 审批失败
     */
    STATUS_APPROVE_FAIL("0", "审批失败"),

    /**
     * 审批成功
     */
    STATUS_APPROVE_SUCCESS("1", "审批成功"),

    /**
     * 终止申请
     */
    STATUS_APPROVE_STOP("2", "终止申请")

    // ======================================================================= //
    ;

    public static Map<String, String> map = new HashMap<>();

    static {
        StatusApproveEnum[] values = StatusApproveEnum.values();
        if (values.length > 0) {
            for (StatusApproveEnum categoryEnum : values) {
                map.put(categoryEnum.getStatusCode(), categoryEnum.getStatusDesc());
            }
        }
    }

    StatusApproveEnum(String statusCode, String statusDesc) {
        this.statusCode = statusCode;
        this.statusDesc = statusDesc;
    }

    /**
     * Code
     */
    @Setter
    @Getter
    private String statusCode;

    /**
     * Desc
     */
    @Setter
    @Getter
    private String statusDesc;

}
